import request from '@/utils/request'

// 获取设备详情
export function getDeviceDetail(deviceNo) {
    return request({
        url: `/api/device/${deviceNo}`,
        method: 'GET'
    })
}

// 开锁
export function unlockDevice(deviceNo) {
    return request({
        url: '/api/device/unlock',
        method: 'POST',
        data: { deviceNo }
    })
}

// 获取附近医院
export function getNearbyHospital(location) {
    return request({
        url: '/api/hospital/nearby',
        method: 'GET',
        data: location
    })
} 